[CMAKE] Fix CMake 4.x build error on MacOS runner and when building opentracing #3649
Merged
marcalff merged 3 commits intoopen-telemetry:mainfrom Sep 22, 2025
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #3649 +/- ##
==========================================
- Coverage 90.09% 90.08% -0.01%
==========================================
Files 220 220
Lines 7110 7110
==========================================
- Hits 6405 6404 -1
- Misses 705 706 +1 🚀 New features to boost your workflow:
|
…ronment variable when building opentracing-cpp to support cmake 4.x
e573c13 to
e1f97f7
Compare
dbarker
commented
Sep 21, 2025
| INSTALL_TEST_DIR: '/Users/runner/install_test' | ||
| CXX_STANDARD: '17' | ||
| CMAKE_TOOLCHAIN_FILE: '/Users/runner/conan/build/Debug/generators/conan_toolchain.cmake' | ||
| CMAKE_VERSION: 3.31.0 # building the conan "stable" versions requires CMake 3.x |
Member
Author
There was a problem hiding this comment.
Downgrading is the most direct and stable solution to fix the CMake 4.x build issue. Many of the dependencies in this "stable" version set depend on CMake versions < 3.5. Later versions of the dependencies (with the exception of opentracing has a minimum of 3.1) build with CMake 4.x.
marcalff
approved these changes
Sep 22, 2025
Merged
3 tasks
1 task
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #3648
CMake 4.x removed compatibility with versions older than 3.5.
https://cmake.org/cmake/help/latest/release/4.0.html#deprecated-and-removed-features
OpenTracing is no longer being updated and sets the minimum CMake version required to 3.1. This creates a CMake configure error when using CMake 4.x.
Older versions of many dependencies depend on minimum versions of CMake < 3.5 (those in the
install/cmake/third_party_<minimum,stable>andinstall/conan/conanfile_stable.txt).Changes
CMAKE_POLICY_VERSION_MINIMUM=3.5when building opentracing-cpp from source using FetchContentconanfile_stable.txtdependency versions.For significant contributions please make sure you have completed the following items:
CHANGELOG.mdupdated for non-trivial changes